<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="../common/jspcommon.jsp"%>
<%@include file="../common/jscss.jsp"%>
<script type="text/javascript">
	var artFlvGrid = null;
	$(function(){
		artFlvGrid = $("#art_flv_grid").ligerGrid({
				title : '展览馆列表',
                columns: [
                          {
                            	display: ' ', 
                            	name: 'id',
                            	isAllowHide: false, 
                            	width: 300,
                            	isSort : false,
            					render: function (record, rowindex, value, column){
            						var html = '<a onclick="deleteFlv(\''+ value + '\')" href="javascript:;">删除</a>&nbsp;'; 
            						return html; 
            					}
                            },
               { display: '展览馆编号', name: 'roomId',isSort : false,width: 100},
	            { display: '视频路径', name: 'src',isSort : false,width: 480},
	            { display: '说明', name: 'descript',isSort : false,width: 100},
                {
                  	display: '<a href="javascript:;">封面</a>', 
                  	name: 'picture',
                  	isAllowHide: false, 
                  	width: 100,
                  	isSort : false,
  					render: function (record, rowindex, value, column){
  						var html = '<a href="'+ value + '" target="_blank">查看</a>'; 
  						return html; 
  					}
                  },
                { display: '创建时间', name: 'gmtCreated',isSort : false,
                  render: function(record, rowindex, value, column){
                	 return (new Date(value.time)).format("yyyy年MM月dd日 hh:mm:ss");
                  }}
              
                ], 
                pageSize:30,
                root :'list',
                record:'totalRecord',
                url: "/misc/artRoom/flvListGrid.htm", 
                width: '99%',height:'99%',
                	isChecked: f_isChecked, onCheckRow: f_onCheckRow, onCheckAllRow: f_onCheckAllRow
            });


	});
	
	function deleteFlv(id){
		$.post("/misc/artRoom/deleteFlv.htm", {
			id:id
		},function(data){
			if(data=="success"){
				artFlvGrid.loadData();
				$.ligerDialog.success("删除成功！");
			}
			if(data=="error"){
				$.ligerDialog.warn("系统有点抽经，请稍候重试！");
			}
		});
	}
</script>
<div id="art_flv_grid" style="margin:0; padding:0"></div>
